<template>
  <el-button type="primary" @click="btnClick" class="btn-search" v-bind="$attrs">
    <slot name="left"></slot>
    {{ name }}
    <slot name="right"></slot>
  </el-button>
</template>

<script>
export default {
  name: 'ZBtn',
  props: {
    name: {
      type: String,
      default: '搜索'
    }
  },
  methods: {
    btnClick() {
      this.$emit('click')
    }
  }
}
</script>

<style lang="scss" scoped>
.btn-search {
  background: linear-gradient(0deg, #1B4BFF, #1BAFFC);
  // border-radius: 4px;
  color: white;
  border: 0;
}
</style>
